import request from '@/utils/request'

// 查询销售合同审核列表
export function listContract(query) {
  return request({
    url: '/task/contract/list',
    method: 'get',
    params: query
  })
}

// 查询销售合同审核详细
export function getContract(id) {
  return request({
    url: '/task/contract/' + id,
    method: 'get'
  })
}

// 新增销售合同审核
export function addContract(data) {
  return request({
    url: '/task/contract',
    method: 'post',
    data: data
  })
}

// 修改销售合同审核
export function updateContract(data) {
  return request({
    url: '/task/contract',
    method: 'put',
    data: data
  })
}

// 删除销售合同审核
export function delContract(id) {
  return request({
    url: '/task/contract/' + id,
    method: 'delete'
  })
}
export function updateStatus (id,updateStatus,comments) {
  return request({
    url: '/task/contract/updateStatus',
    method: 'put',
    params: {
      id,updateStatus,comments
    }
  })
}
